package figuriConcrete;
import java.util.*;

import figuriAbstracte.*;

public class Line extends LinePoint{
	private ArrayList<Point> points;
	public void createPoints()
	{
		this.points=new ArrayList<Point>(2);
	}
	public ArrayList<Point> getPoints()
	{
		return this.points;
	}
	public void setPoints(ArrayList<Point> p)
	{
		this.points=p;
	}
	public double getLength()
	{
		return this.points.get(0).distance(this.points.get(1));
	}
	public String toString()
	{
		return "Linia este formata din urmatoarele puncte: "+points.get(0)+" "+
		points.get(1);
	}

}
